﻿using Microsoft.AspNetCore.Mvc;
using Microsoft.Extensions.Options;

namespace SmartFactory.Controllers
{
    public class OrdersController : Controller
    {
        private readonly IpAddressesConfig _ipAddressesConfig;

        public OrdersController(IOptions<IpAddressesConfig> ipAddressesConfig)
        {
            _ipAddressesConfig = ipAddressesConfig.Value;
        }
        public IActionResult Index()
        {
            return View();
        }
        /// <summary>
        /// 订单列表
        /// </summary>
        /// <returns></returns>
        public IActionResult OrderShowView()
        {
            ViewBag.Darius = _ipAddressesConfig.Darius;
            ViewBag.Durian = _ipAddressesConfig.Durian;
            ViewBag.GlennQuigmrire = _ipAddressesConfig.GlennQuigmrire;
            ViewBag.Keep = _ipAddressesConfig.Keep;
            return View();
        }
        /// <summary>
        /// 订单新增
        /// </summary>
        /// <returns></returns>
        public IActionResult OrderAddView()
        {
            ViewBag.Darius = _ipAddressesConfig.Darius;
            ViewBag.Durian = _ipAddressesConfig.Durian;
            ViewBag.GlennQuigmrire = _ipAddressesConfig.GlennQuigmrire;
            ViewBag.Keep = _ipAddressesConfig.Keep;
            return View();
        }
        /// <summary>
        /// 产品列表
        /// </summary>
        /// <returns></returns>
        public IActionResult ProductShowView()
        {
            ViewBag.Darius = _ipAddressesConfig.Darius;
            ViewBag.Durian = _ipAddressesConfig.Durian;
            ViewBag.GlennQuigmrire = _ipAddressesConfig.GlennQuigmrire;
            ViewBag.Keep = _ipAddressesConfig.Keep;
            return View();
        }
        /// <summary>
        /// 导入
        /// </summary>
        /// <returns></returns>
        public IActionResult ImportProductView()
        {
            ViewBag.Darius = _ipAddressesConfig.Darius;
            ViewBag.Durian = _ipAddressesConfig.Durian;
            ViewBag.GlennQuigmrire = _ipAddressesConfig.GlennQuigmrire;
            ViewBag.Keep = _ipAddressesConfig.Keep;
            return View();
        }
        /// <summary>
        /// 打印
        /// </summary>
        /// <returns></returns>
        public IActionResult HiprintView()
        {
            ViewBag.Darius = _ipAddressesConfig.Darius;
            ViewBag.Durian = _ipAddressesConfig.Durian;
            ViewBag.GlennQuigmrire = _ipAddressesConfig.GlennQuigmrire;
            ViewBag.Keep = _ipAddressesConfig.Keep;
            return View();
        }
        /// <summary>
        /// 反填
        /// </summary>
        /// <returns></returns>
        public IActionResult OrderGetView()
        {
            ViewBag.Darius = _ipAddressesConfig.Darius;
            ViewBag.Durian = _ipAddressesConfig.Durian;
            ViewBag.GlennQuigmrire = _ipAddressesConfig.GlennQuigmrire;
            ViewBag.Keep = _ipAddressesConfig.Keep;
            return View();
        }
        /// <summary>
        /// 订单审批
        /// </summary>
        /// <returns></returns>
        public IActionResult OrderApprovalView()
        {
            ViewBag.Darius = _ipAddressesConfig.Darius;
            ViewBag.Durian = _ipAddressesConfig.Durian;
            ViewBag.GlennQuigmrire = _ipAddressesConfig.GlennQuigmrire;
            ViewBag.Keep = _ipAddressesConfig.Keep;
            return View();
        }
    }
}
